Computer networks often have a client-server configuration, in which one or more clients are connected to a server via a communication medium, such as an Ethernet link. The server provides one or more services to the clients. For example, the server may provide messaging services or file storage services to computer workstation clients.
Clients in a client-server configuration often must send messages among each other via the server For example, two computerized instruments in a spacecraft may be connected to a server. The two computerized instruments, which are clients of the server, may exchange messages with each other via the server.
A messaging system may be implemented to handle the transfer of messages among clients of a computer network having a client-server configuration. The messaging system typically has one or more message oriented middleware servers (“MOM servers”) for processing messages. Each client is connected to a MOM server of the messaging system.
Many messaging systems include at least two MOM servers. A group of two or more MOM servers is commonly referred to as a cluster. Advantages of processing messages via a cluster instead of via a single MOM server may include improved reliability and increased capacity. For example, if one MOM server in a cluster fails, the remaining one or more MOM servers may still be able to handle all of the cluster's message transferring requirements. As another example, a messaging system having a cluster may have a greater message processing capability than a messaging system having only a single MOM server.
MOM servers in a cluster cooperate in the transferring of messages between clients. It is not necessary for clients to be connected to the same MOM server in order for them to transfer messages among themselves. For example, consider a cluster having two MOM servers and two clients. One client is connected to one MOM server, and the other client is connected to the other MOM server. Because both clients are connected to the same cluster, they can exchange messages with each other even though they are connected to different MOM servers.
A MOM server generally has a plurality of server processes. Server processes are MOM server elements that provide certain functions for the MOM server. For example, a MOM server may include a client interface process to handle a connection between the MOM server and a client. As another example, a MOM server may also include a message routing process to help the MOM server route messages to clients.
Server processes may have a plurality of operating states. For example, a client interface process may have a client connected operating state and a client disconnected operating state. A message routing process may have an operating state corresponding to each of a group of possible message categories.
Server processes may need to transition from one operating state to another. For example, a client interface process may need to transition from a connected operating state to a disconnected operating state if a client wishes to disconnect from the MOM server. As another example, an internal component of the MOM server may need to transition from an initializing operating state to a normal operating state during server boot-up.
A server process may transition from one operating state to another by executing a state transition command. A state transition command is an instruction which instructs a server process to transition from one operating state to another.
It is often necessary to synchronize execution of state transition commands among MOM servers in a cluster. For example, synchronization may be required to prevent two or more incompatible state transition commands from being executed simultaneously. Synchronization of the execution of state transition commands can be accomplished by implementing algorithms that guarantee that solely one state transition command can be executed at a given time. However, such algorithms are typically complex and therefore, difficult and expensive to design, implement, debug, and test. Such algorithms typically become even more complex when the quantity of active MOM servers within the cluster may vary due to MOM servers entering and leaving the cluster. Therefore, a simpler method of synchronizing execution of state transition commands among MOM servers in a cluster is needed.